feat: support GTS spec v0.14.4 - #128
Conversation
Pin the conformance suite to v0.14.4. The release adds the batch registration contract to README §9.3 and new tests for it, plus a few corner cases: - `POST /type-schemas` honors `?validate` and `gts-ref-validation` like `/entities`. A malformed mode is refused with 422 before any entry is registered. - With `validate=true` the whole batch is staged first, so an entry may `$ref` or derive from one later in the array. Staged entries are then validated until no new failure appears: a rejected entry is unstaged and the survivors are re-checked, so nothing commits on top of a rejected sibling. The batch may partly succeed; a rejected entry never commits, and an id already stored with the same content stays stored. - The trait-schema integrity check compiles each `x-gts-traits-schema` fragment under the host document's dialect instead of the default draft, so a Draft-07 tuple `items: [...]` is no longer rejected. `GtsOps::add_schemas` keeps its behavior; the new `add_schemas_with` takes the `validate` flag and the reference-validation mode. Signed-off-by: Aviator 5 <ai.agent.tor@gmail.com>
|
Navigate logical layers of code changes, visualize relationships, and explore their blast radius. No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: defaults Review profile: CHILL Plan: Advanced Run ID: 📒 Files selected for processing (6)
Included review availability: This review used your included allowance. Your plan provides up to 1 included review per hour; 0 remain after this review. 📝 WalkthroughWalkthroughThe CLI batch schema endpoint now supports validation and reference-validation modes. Batch registration validates entries and removes invalid new schemas, including dependents of rejected entries. Trait integrity checks use the host schema dialect for fragments without their own dialect. The supported specification version is now 0.14.4. ChangesBatch schema registration
Trait schema dialect validation
Priority: ➖ Normal Estimated code review effort: 3 (Moderate) | ~25 minutes Change: Feature Suggested reviewers: Merge Risk: ⚪ Minimal · up to No identified issue blocks merging after normal checks. Security Architecture ReviewSecurity architecture risk: 🔵 Low · up to Batch registration now has more complex validation and partial-success behavior, but the reviewed paths preserve the existing unvalidated option and did not establish a new security bypass. Deployment controls and resource limits remain unverified. Retained concerns Security review detailsSecurity Blast Radius
Trust Boundaries and Controls
Resilience and Maintainability Implications
Hardening Proposals
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
code-rankerBuilt on a fork. View full report ↗ rust
|
|
Codecov Report✅ All modified and coverable lines are covered by tests. 📢 Thoughts on this report? Let us know! |
Pin the conformance suite to v0.14.4. The release adds the batch registration contract to README §9.3 and new tests for it, plus a few corner cases:
POST /type-schemashonors?validateandgts-ref-validationlike/entities. A malformed mode is refused with 422 before any entry is registered.validate=truethe whole batch is staged first, so an entry may$refor derive from one later in the array. Staged entries are then validated until no new failure appears: a rejected entry is unstaged and the survivors are re-checked, so nothing commits on top of a rejected sibling. The batch may partly succeed; a rejected entry never commits, and an id already stored with the same content stays stored.x-gts-traits-schemafragment under the host document's dialect instead of the default draft, so a Draft-07 tupleitems: [...]is no longer rejected.GtsOps::add_schemaskeeps its behavior; the newadd_schemas_withtakes thevalidateflag and the reference-validation mode.Summary by CodeRabbit
itemsbehavior.